What is ActiveX?

by Mark Davis
People who create home pages for the World Wide Web quickly find out that HTML (the language used to create Web pages) is a great way to present static information (text and graphics) that doesn't need to interact with the user. HTML is very limited, however, when it comes to creating interactive features such as database front-ends and forms that can respond and change depending on user input. To add such features to your home pages, you can either use the Java language (championed by Sun Microsystems) or use Microsoft's solution, ActiveX. ActiveX is actually a set of technologies designed to make the Web a more interactive and user friendly environment. While similar in some ways to Java, ActiveX has a number of differences that users need to be aware of when deciding on which technology to use to spice up their home pages.

First of all, unlike Java, ActiveX currently works only in the Windows environment (although Microsoft is working with other companies to port it to the Macintosh and UNIX platforms). It is based on the OLE (Object Linking and Embedding) and COM (Component Object Model) technologies that Microsoft® has been working on for years. ActiveX controls, for example, are actually modified versions of the standard OLE and OCX controls that users of languages such as C++ and Visual Basic have used for years. They have been changed, however, to make them smaller and faster than traditional OLE controls. This is necessary because ActiveX controls, like Java applets, must first be downloaded to the user's PC before they can be executed. ActiveX controls are not deleted from the PC after use, however, unlike Java applets, so they remain on the user's hard drive and can be run again at a later date without having to download them again. Over 1,000 commercial ActiveX controls are already available for use by Web developers, and range in complexity from simple pushbuttons and data entry forms to complete spreadsheet and database modules. ActiveX controls can be created in languages as varied as C++ or Visual Basic, so developers can easily select the type of language they wish to develop in, which ensures that many more ActiveX controls will be developed in the future.

ActiveX controls are generally more powerful and faster than Java applets due to the fact that they are based on compiled native Windows code (rather than being generic byte codes executed in a virtual machine, as occurs with Java). The tradeoff here is that you lose cross-platform compatibility, since ActiveX is solely Windows-based at this time. Another more serious problem is that ActiveX controls do not have the limitations placed on them that Java code has. They execute directly within your operating system (not in a separate virtual machine), and can access files and other system resources such as memory (Java applets can't do this).  This makes it easier to create controls that can search your hard drive for information or perform malicious acts such as deleting or modifying files. Microsoft is working on ways to enhance the security of ActiveX controls, however. One way to do this is through the creation of digital signatures (which Microsoft calls Authenticode). These digital signatures allow vendors to create digital certificates that are verified and licensed by independent companies. These certificates let users identify the creator of an ActiveX control before it's downloaded to their PC. Users can then decide whether or not they trust that vendor before allowing their ActiveX control to access their machine. While ActiveX controls are a large part of the ActiveX story, there are other parts of ActiveX as well. VBScript is a Web-adapted subset of Visual Basic for Applications, the scripting language found in Microsoft Office. For security reasons, VBScript won't let you directly access your PC's files or memory. It does let you create scripts that can manipulate HTML objects such as text boxes and buttons on a page. VBScript can also control the execution of ActiveX controls or Java applets within a page, which makes it a very powerful addition to the Web developer's toolbox. ActiveX documents are non-HTML files (such as Word or Excel) that can be viewed from within a Web browser. There is also an ActiveX server technology called Active Server Pages that let you run scripts and ActiveX controls on a Web server to allow access to remote databases and to perform financial and other transactions. Much has been made in the computing media lately about the supposed rivalry between ActiveX and Java. In reality, they actually complement each other very nicely. For example, ActiveX can easily be used to expose Java applets and give them the ability to do things they can't do by themselves (like read/write files or access the PC's hardware, which can make them much more powerful and useful). Java itself can be used, in turn, to create cross-platform ActiveX controls that can be used in different computing environments (once ActiveX is available on other platforms, that is). Microsoft's Visual J++ is a bridge product between the two technologies that makes it easy to create both Java applets and ActiveX controls and easily integrate them into programs. Products such as Visual J++ will ensure that developers can use the best features of both Java and ActiveX on any projects they are working on, selecting whichever technology works best for the task at hand.

     As you can see, ActiveX is a very powerful and important set of technologies! Currently, only Microsoft's Internet Explorer Web browser supports the full ActiveX feature set (although you can run ActiveX controls in Netscape if you download a plug-in module from a company called NCompass Labs at www.ncompasslabs.com). ActiveX should continue to grow in popularity and be supported by more browsers in the future, and will not only coexist with Java, but will help to make it a more powerful technology as well. Needless to say, if you're at all interested in the Internet, you'll be seeing and hearing a lot more about ActiveX in the future!

Gateway offers this column to its readership as a service, but please note that it is not responsible for the accuracy or opinions of the author and offers no warranty either expressed or implied that the information will produce the desired result.

The information provided in this article is based upon the writers particular experience with certain equipment. Familiarize yourself with the requirements of your local and state electrical code and insure yourself that the work you plan to do does not require a licensed professional. If you decide to attempt to do the work yourself, always exercise extreme caution when working on electrical systems because accidents may cause serious injury including death and damage your computer. If you experience difficulty or do not understand the instructions, please consult a professional in your area.



[Products] [Global Site] [Tech Support] [Corporate Information] [The Cow Zone] [What's New] [Glossary] [Search] [Home]

[Gateway 2000]
Copyright © 1996 Gateway 2000 Inc. All rights reserved.
Please see our Legal Information. Please send feedback to Webmaster Central.